#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <fcntl.h>
#include <sys/stat.h>
#include <stdlib.h>

void copy(int src_fd, int dst_fd) {
	char buf[512];
	int count;
	while((count = read(src_fd,buf,512)))
		write(dst_fd,buf,count);
}

int main(int argc, char *argv[]) {
	int fd;
/*	if(argc > 2) {
		printf("input error\n");
		return 0;
	}*/
	//int temp1,temp2;
	//if(argv[1][0] == '<') temp1 = 0;
	//if(argv[1][0] == '>') temp2 = 0;
	printf("%s %s\n",argv[0],argv[1]);
/*	char *path = malloc(strlen(argv[1]));
	strcpy(path,argv[1]);

	if(argv[1][0] == '<') {
		fd = open(strtok(path,"<"),O_RDONLY);
	}
	else if(argv[1][0] == '>') {
		fd = 0;
	}
	else {
		fd = open(argv[1],O_RDONLY);
	}
	copy(fd,1);
*/	return 0;
}
